package com.byxx.gtz.devicemonitoringsysejb.entity;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.FetchType;
import javax.persistence.Id;
import javax.persistence.JoinColumn;
import javax.persistence.ManyToOne;
import javax.persistence.Table;

/**
 * DeviceMonitor entity. @author MyEclipse Persistence Tools
 */
@Entity
@Table(name = "DEVICE_MONITOR", schema = "DEVICE_FSX")

public class DeviceMonitor implements java.io.Serializable {

	// Fields

	private String deviceId;
	private Region region;
	private String deviceName;
	private String deviceType;
	private int deviceRunning;
	private String deviceStatus;
	private String controlMode;
	private String controlType;
	private String floor;
	private int coordsX;
	private int coordsY;
	private String note;

	// Constructors

	/** default constructor */
	public DeviceMonitor() {
	}

	/** minimal constructor */
	public DeviceMonitor(String deviceId) {
		this.deviceId = deviceId;
	}

	/** full constructor */
	public DeviceMonitor(String deviceId, Region region, String deviceName, String deviceType, int deviceRunning,
			String deviceStatus, String controlMode, String controlType, String floor, int coordsX, int coordsY,
			String note) {
		this.deviceId = deviceId;
		this.region = region;
		this.deviceName = deviceName;
		this.deviceType = deviceType;
		this.deviceRunning = deviceRunning;
		this.deviceStatus = deviceStatus;
		this.controlMode = controlMode;
		this.controlType = controlType;
		this.floor = floor;
		this.coordsX = coordsX;
		this.coordsY = coordsY;
		this.note = note;
	}

	// Property accessors
	@Id

	@Column(name = "DEVICE_ID", unique = true, nullable = false, length = 36)

	public String getDeviceId() {
		return this.deviceId;
	}

	public void setDeviceId(String deviceId) {
		this.deviceId = deviceId;
	}

	@ManyToOne(fetch = FetchType.LAZY)
	@JoinColumn(name = "REGION_ID")

	public Region getRegion() {
		return this.region;
	}

	public void setRegion(Region region) {
		this.region = region;
	}

	@Column(name = "DEVICE_NAME", length = 100)

	public String getDeviceName() {
		return this.deviceName;
	}

	public void setDeviceName(String deviceName) {
		this.deviceName = deviceName;
	}

	@Column(name = "DEVICE_TYPE", length = 100)

	public String getDeviceType() {
		return this.deviceType;
	}

	public void setDeviceType(String deviceType) {
		this.deviceType = deviceType;
	}

	@Column(name = "DEVICE_RUNNING", precision = 38, scale = 0)

	public int getDeviceRunning() {
		return this.deviceRunning;
	}

	public void setDeviceRunning(int deviceRunning) {
		this.deviceRunning = deviceRunning;
	}

	@Column(name = "DEVICE_STATUS", length = 100)

	public String getDeviceStatus() {
		return this.deviceStatus;
	}

	public void setDeviceStatus(String deviceStatus) {
		this.deviceStatus = deviceStatus;
	}

	@Column(name = "CONTROL_MODE", length = 50)

	public String getControlMode() {
		return this.controlMode;
	}

	public void setControlMode(String controlMode) {
		this.controlMode = controlMode;
	}

	@Column(name = "CONTROL_TYPE", length = 50)

	public String getControlType() {
		return this.controlType;
	}

	public void setControlType(String controlType) {
		this.controlType = controlType;
	}

	@Column(name = "FLOOR", length = 50)

	public String getFloor() {
		return this.floor;
	}

	public void setFloor(String floor) {
		this.floor = floor;
	}

	@Column(name = "COORDS_X", precision = 38, scale = 0)

	public int getCoordsX() {
		return this.coordsX;
	}

	public void setCoordsX(int coordsX) {
		this.coordsX = coordsX;
	}

	@Column(name = "COORDS_Y", precision = 38, scale = 0)

	public int getCoordsY() {
		return this.coordsY;
	}

	public void setCoordsY(int coordsY) {
		this.coordsY = coordsY;
	}

	@Column(name = "NOTE", length = 100)

	public String getNote() {
		return this.note;
	}

	public void setNote(String note) {
		this.note = note;
	}

}